home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Borland / Borland C++ V5.02 / CLOBSH.PAK / DICT.H < prev    next >
C/C++ Source or Header  |  1997-05-06  |  2KB  |  71 lines

  1. /*------------------------------------------------------------------------*/
  2. /*                                                                        */
  3. /*  DICT.H                                                                */
  4. /*                                                                        */
  5. /*  Copyright Borland International 1991, 1993                            */
  6. /*  All Rights Reserved                                                   */
  7. /*                                                                        */
  8. /*------------------------------------------------------------------------*/
  9.  
  10. #if !defined( __DICT_H )
  11. #define __DICT_H
  12.  
  13. #define BI_OLDNAMES
  14.  
  15. #if !defined( __STDLIB_H )
  16. #include <stdlib.h>
  17. #endif
  18.  
  19. #if !defined( __CLSTYPES_H )
  20. #include "classlib\obsolete\ClsTypes.h"
  21. #endif  // __CLSTYPES_H
  22.  
  23. #if !defined( __OBJECT_H )
  24. #include "classlib\obsolete\Object.h"
  25. #endif  // __OBJECT_H
  26.  
  27. #if !defined( __SET_H )
  28. #include "classlib\obsolete\Set.h"
  29. #endif  // __SET_H
  30.  
  31. #pragma option -Vo-
  32. #if defined( __BCOPT__ ) && !defined( __FLAT__ ) && !defined( _ALLOW_po )
  33. #pragma option -po-
  34. #endif
  35.  
  36. _CLASSDEF(Association)
  37. _CLASSDEF(Dictionary)
  38.  
  39. class _CLASSTYPE Dictionary : public Set
  40. {
  41.  
  42. public:
  43.  
  44.     Dictionary( unsigned sz = DEFAULT_HASH_TABLE_SIZE ) :
  45.         Set(sz)
  46.         {
  47.         }
  48.  
  49.     virtual void add( Object _FAR & );
  50.     Association _FAR & lookup( const Object _FAR & ) const;
  51.  
  52.     virtual classType isA() const
  53.         {
  54.         return dictionaryClass;
  55.         }
  56.  
  57.     virtual _TCHAR _FAR *nameOf() const
  58.         {
  59.         return "Dictionary";
  60.         }
  61.  
  62. };
  63.  
  64. #if defined( __BCOPT__ ) && !defined( __FLAT__ ) && !defined( _ALLOW_po )
  65. #pragma option -po.
  66. #endif
  67. #pragma option -Vo.
  68.  
  69. #endif  // __DICT_H
  70.  
  71.